package model

type PayOutStatus int

const PAY_OUT_ING PayOutStatus = 0
const PAY_OUT_SUCCESS PayOutStatus = 1
const PAY_OUT_FAILD PayOutStatus = 2

type PayType string

const PT_PayTm PayType = "paytm"
const PT_BANK PayType = "bank"
const PT_UPI PayType = "upi"

/**
出金表
*/
type PayOut struct {
	Id         int64        `json:"id"`
	AppId      AppId        `xorm:"app_id" json:"app_id"`
	PayChannel PayChannel   `xorm:"pay_channel" json:"pay_channel"`
	AppOrderId string       `xorm:"app_order_id" json:"app_order_id"`
	PayType    PayType      `xorm:"pay_type" json:"pay_type"`
	Amount     int64        `xorm:"amount" json:"amount"`
	UniqId     string       `xorm:"uniq_id" json:"uniq_id"`
	UserId     int64        `xorm:"user_id" json:"user_id"`
	UserName   string       `xorm:"user_name" json:"user_name"`
	Phone      string       `xorm:"phone" json:"phone"`
	Email      string       `xorm:"email" json:"email"`
	Paytm      string       `xorm:"paytm" json:"paytm"`
	BankCard   string       `xorm:"bank_card" json:"bank_card"`
	Address    string       `xorm:"address" json:"address"`
	Status     PayOutStatus `xorm:"status" json:"status"`
	ThirdCode  string       `xorm:"third_code" json:"third_code"`
	ThirdDesc  string       `xorm:"third_desc" json:"third_desc"`
	Created    int64        `xorm:"created" json:"created"`
	Updated    int64        `xorm:"updated" json:"updated"`
}

type PayOutCallbacks struct {
}

/**
回调数据结构体
*/
type PayOutCallbackData struct {
	PaymentOrderId string    `json:"payment_order_id"`
	Status         PayStatus `json:"status"`
}
